package org.vergil.core.mq;

/**
 * Created by vergil on 3/2/17.
 */
//@Component
//@EnableJms
public class SpringMq {
    //当收到消息后，自动调用该方法,spring配置默认监听器，负责接收消息
//    @JmsListener(containerFactory="jmsListenerContainerFactory",destination = "mssactivemq")
//    public void onMessage(Message message) {
//        TextMessage tm = (TextMessage) message;
//        try {
//            System.out.println(tm.getText());
//        } catch (JMSException e) {
//            e.printStackTrace();
//        }
//    }

}
